package cn.cheln.support.manager.listener;

import android.app.Activity;
import cn.cheln.explorer.func.setup.PackageInstallManager;
import java.util.HashSet;
import java.util.Set;

public class HomeListener
{
  public static Activity activityOnKeyHome;
  public static Set<Activity> displayingActivitySum = new HashSet();

  public static void addInstance(Activity paramActivity)
  {
    if (displayingActivitySum == null)
      return;
    displayingActivitySum.add(paramActivity);
  }

  public static void handleResume_backResume(Activity paramActivity)
  {
    if ((activityOnKeyHome == null) || (activityOnKeyHome != paramActivity))
      return;
    PackageInstallManager.homeStopFlag = false;
    activityOnKeyHome = null;
  }

  public static void removeInstance(Activity paramActivity)
  {
    if (displayingActivitySum == null)
      return;
    displayingActivitySum.remove(paramActivity);
    if (displayingActivitySum.size() != 0)
      return;
    activityOnKeyHome = paramActivity;
    stopInstall();
  }

  public static void stopInstall()
  {
    PackageInstallManager.getInstance();
    if (!(PackageInstallManager.isInInstall))
      return;
    PackageInstallManager.homeStopFlag = true;
    PackageInstallManager.getInstance().endWhileAppAlive();
  }
}

/* Location:           H:\360云盘\lewa_explorer_3.0\bin\FileApp_orig_dex2jar.jar
 * Qualified Name:     cn.cheln.support.manager.listener.HomeListener
 * JD-Core Version:    0.5.2
 */